package com.ukao.steward.adapter;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.TextView;

import com.ukao.steward.R;
import com.ukao.steward.bean.businessWholeBean;
import com.ukao.steward.util.CheckUtils;
import com.ukao.steward.widget.FlowLayout;
import com.ukao.steward.widget.TagAdapter;

import java.util.ArrayList;

/**
 * Created by ukaodev on 2017/6/14.
 */

public class ClothingTagAdapter extends TagAdapter<businessWholeBean.TypeListBean> {

     private   Context  mContext;

    public ClothingTagAdapter(Context  mContext, ArrayList<businessWholeBean.TypeListBean> datas) {
        super(datas);
        this.mContext=mContext;
    }


    @Override
    public View getView(FlowLayout parent, int position, businessWholeBean.TypeListBean item) {

        TextView mTextView=(TextView)LayoutInflater.from(mContext).inflate(R.layout.adapter_clothing_tag,
                parent, false);
        mTextView.setText(CheckUtils.isEmptyString(item.getName()));
        return mTextView;
    }
}
